#!/bin/sh
startYear=1994
endYear=2007

while [ $startYear -le $endYear ]
do
	count=`wc ${startYear}.group | awk '{print $1}'`
	#if [ $((count%10)) = 0 ]
	#then
	#	count=$((count/10))
	#else
	#	count=$((count/10+1))
	#fi
	#echo $count
	awk -f divide.awk total=$count ${startYear}.group > ${startYear}.group.txt

	startYear=$((startYear+1))
done